"""
---------------------------------------------------------------------
- File: api_doc.py
- Date: 2025/11/5
- Author: yangzhide
- Email: xxzjyzd@126.com
- Description: 
---------------------------------------------------------------------
"""
from fastapi import APIRouter, FastAPI
from scalar_fastapi import get_scalar_api_reference

app = FastAPI()
doc_router = APIRouter()


# api-doc(scalar-doc)
@doc_router.get("/scalar-doc", include_in_schema=False)
async def scalar_doc():
    """
    API 文档，
    """
    return get_scalar_api_reference(
        openapi_url=app.openapi_url,
        title="API文档",
        content=None,
    )